<!doctype html>
<html lang="zh-CN">
    <head>
        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/>
        <meta name="renderer" content="webkit" />
	    <meta name="viewport" content="initial-scale=1,maximum-scale=1,user-scalable=no,width=device-width,height=device-height">
        <title>About</title>
        <link href="favicon.ico" rel="shortcut icon">
        <script src="https://unpkg.com/axios/dist/axios.min.js"></script>
        <script src="./js/common/vue.js"></script>
        <script src="./js/common/vue-resource.js"></script>
        <link rel="stylesheet" href="css/common/swiper.css">
        <link rel="stylesheet" href="css/common/base.css">
        
        <link rel="stylesheet" href="css/common/media.css">
        <link rel="stylesheet" href="css/about.css">
    </head>
    <body>
        <div id="contn">
            <v-header></v-header>
            <v-main :parent-nav="nav" :parent-currentind="currentind" :parent-blocks="blocks" :parent-banner="banner" :parent-teambg="teambg" :parent-team="team" :parent-advisor="advisor" :parent-clbrtn="clbrtn"></v-main>
            <v-footer></v-footer>
        </div>
        <template id="vMain">
            <main>
                <div class="heading">
                    <div class="storeBox" v-if="parentNav.length" v-html="parentNav[parentCurrentind].htmlContent"></div>
                    <p class="pic fill"><img v-if="parentNav.length" :src="parentNav[parentCurrentind].imagePath" class="obj-c" alt=""></p>
                    <div class="fluid flex flex-align-items fill">
                        <div class="txt ready">
                             <p class="delay-1" v-if="parentNav.length">{{parentNav[parentCurrentind].enName}}</p>
                             <p class="delay-2"></p>
                        </div>
                    </div>
                </div>
                <div class="tips">
                    <p></p>
                </div>
                <div class="pics ready overHalf fillAft">
                    <div class="txt" v-if="parentBlocks.length" v-html="parentBlocks[0].htmlContent"></div>
                    <div class="palace fill">
                        <div class="swiper-container picSwp">
                            <div class="swiper-wrapper">
                                <div class="swiper-slide" v-for="(item,i) in parentBanner">
                                    <img :src="item" class="obj-c" alt="">
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="professor">
                    <div class="storeBox" v-if="parentBlocks.length" v-html="parentBlocks[1].htmlContent"></div>
                    <div class="fluid">
                        <div class="content flex flex-align-items">
                            <div class="avatar ready">
                                <div class="intro fill">
                                    <p class="postn" v-if="parentBlocks.length">{{parentBlocks[1].title}}</p>
                                    <p class="name" v-if="parentBlocks.length">{{parentBlocks[1].description}}</p>
                                    <div class="draw fill"></div>
                                </div>
                                <img v-if="parentBlocks.length" :src="parentBlocks[1].imagePath" alt="">
                            </div>
                            <p class="txt"></p>
                        </div>
                    </div>
                </div>
                <div id="team">
                    <div class="specific hvc">
                        <p class="close cursor"></p>
                        <p class="avatar"><img src="" alt=""></p>
                        <p class="name"></p>
                        <div class="intro"></div>
                    </div>
                    <div class="fluid">
                        <p v-if="parentTeam.length">{{parentTeam[0].category}}</p>
                        <div class="list flex flex-justify-content">
                            <div class="itm cursor ready overHalf" v-for="(item,i) in parentTeam">
                                <div class="storeBox" v-html="item.htmlContent"></div>
                                <div class="avatar">
                                    <img :src="item.imagePath" class="obj-c fill person" alt="">
                                    <img :src="parentTeambg" alt="" class="fill obj-c bg">
                                    <p class="draw fill"></p>
                                </div>
                                <div class="txt">
                                    <p class="name">{{item.title}}</p>
                                    <p class="des"></p>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div id="advisor">
                    <div class="fluid">
                        <p v-if="parentAdvisor.length">{{parentAdvisor[0].category}}</p>
                        <div class="list flex flex-justify-content">
                            <div class="itm ready" v-for="(item,i) in parentAdvisor">
                                <p class="name">{{item.title}}</p>
                                <div class="des" v-html="item.htmlContent"></div>
                            </div>
                        </div>
                    </div>
                </div>
                <div id="collaboration">
                    <div class="fluid">
                        <div class="box flex" v-for="(item,i) in parentClbrtn">
                            <img class="ready overHalf" :src="item.imagePath" alt="">
                            <div class="t" v-html="item.htmlContent"></div>
                        </div>
                    </div>
                </div>
           </main>
        </template>

        
        <script src="js/common/swiper.js"></script>
        <script src="js/common/jquery.js"></script>
        <script src="./js/common/dataUrl.js"></script>
        <script src="js/common/header.js"></script>
        <script src="js/common/footer.js"></script>
        <script>
            var contn = new Vue({
                el:'#contn',
                data:{
                    banner:[],
                    currentind:'',
                    nav:[],
                    blocks:[],
                    teambg:'',
                    team:[],
                    advisor:[],
                    clbrtn:[]
                },
                methods:{
                    writingWeb:function(){
                        //获取heading
                        axios.get(dataUrl + 'api/getNavbar',{
                            headers:{
                                Authorization: headers
                            }
                        })
                        .then((res) => {
                            //console.log(res.data.data);
                            this.nav = res.data.data;
                            for(var a = 0;a < res.data.data.length;a++){
                                if(window.location.href.indexOf('html') < 0){
                                    this.currentind = 0;
                                }else if(window.location.href.indexOf(res.data.data[a].visitUrl) >= 0){
                                    this.currentind = a;
                                }
                            }
                            setTimeout(function(){
                                $('main .heading .fluid .txt p:eq(1)').text($('main .heading .storeBox p:eq(0)').text());
                                $('main .tips p').text($('main .heading .storeBox p:eq(1)').text());
                            },)
                        });
                       //获取其他板块
                       axios.post(dataUrl + 'api/getArchivesDetails',{ext06:0,id:73,size:10000,page:1},{
                            headers:{
                                Authorization: headers
                            }
                        })
                        .then((res) => {
                            //console.log(res.data.data);
                            this.blocks = res.data.data.list;
                            var This = this;
                            setTimeout(function(){
                                $('main .professor .storeBox img').addClass('fill');
                                $('main .professor .storeBox img').addClass('obj-c');
                                $('main .professor .content .txt').html($('main .professor .storeBox p:eq(0)').html());
                                $('main .professor .content .avatar').prepend($('main .professor .storeBox img:eq(0)'));
                                $('main .professor .content .avatar .intro').append($('main .professor .storeBox img:eq(0)'));
                                
                            },10)
                        })

                        //获取team list
                        axios.post(dataUrl + 'api/getArchivesDetails',{ext06:0,id:83,size:10000,page:1},{
                            headers:{
                                Authorization: headers
                            }
                        })
                        .then((res) => {
                            //console.log(res.data.data);
                            this.team = res.data.data.list;
                            setTimeout(function(){
                                $('main #team .list .itm .des').html($('main #team .list .itm .storeBox p:eq(0)').html());
                                $('main #team .list .itm').mouseenter(function(){
                                    if($(this).find('canvas').length <= 0){
                                        $(this).find('.draw').append($('main #team .list .itm canvas')[0]);
                                        var This = $(this);
                                        setTimeout(function(){
                                            This.addClass('active');
                                        },10)
                                    }else{
                                        $(this).addClass('active');
                                    }
                                })
                                $('main #team .list .itm').click(function(){
                                    if($('main #team .list .itm.disappear').length){
                                        $('main #team .list .itm').removeClass('disappear');
                                    }else{
                                        setTimeout(function(){
                                            $('main #team .specific').addClass('show');
                                        },10)
                                    }
                                    $(this).addClass('disappear');
                                    $('main #team .specific .avatar img').attr('src',$(this).find('.person').attr('src'));
                                    $('main #team .specific .name').text($(this).find('.name').text());
                                    $('main #team .specific .intro').html($(this).find('.storeBox').html());
                                    
                                })
                                $('main #team .list .itm').mouseleave(function(){
                                    $('main #team .list .itm').removeClass('active');
                                })
                            },10)
                        })
                        //获取advisor list
                        axios.post(dataUrl + 'api/getArchivesDetails',{ext06:0,id:84,size:10000,page:1},{
                            headers:{
                                Authorization: headers
                            }
                        })
                        .then((res) => {
                            //console.log(res.data.data);
                            this.advisor = res.data.data.list;
                        })
                        //获取collaboration list
                        axios.post(dataUrl + 'api/getArchivesDetails',{ext06:0,id:85,size:10000,page:1},{
                            headers:{
                                Authorization: headers
                            }
                        })
                        .then((res) => {
                            //console.log(res.data.data);
                            this.clbrtn = res.data.data.list;
                        })

                        //获取部分图片
                        axios.post(dataUrl + 'api/getBanner',{identification:'OTHER_PICS'},{
                            headers:{
                                Authorization: headers
                            }
                        })
                        .then((res) => {
                            //console.log(res.data.data);
                            for(var n = 0;n < res.data.data.length;n++){
                                if(res.data.data[n].remark == 'about'){
                                    if(res.data.data[n].ext01 == 'team bg'){
                                        this.teambg = res.data.data[n].imgPath;
                                    }else{
                                        this.banner.push(res.data.data[n].imgPath);
                                    }
                                }
                            }
                        });
                        //获取列表
                        /*axios.post(dataUrl + 'api/getArchivesDetails',{ext06:0,id:82,size:10000,page:1},{
                            headers:{
                                Authorization: headers
                            }
                        })
                        .then((res) => {
                            console.log(res.data.data);
                        })*/
                    }
                },
                created:function(){
                    this.writingWeb();
                },
                mounted:function(){
                    ifMounted = true;
                },
                components:{
                    vMain:{
                        template: '#vMain',
                        methods:{
                            
                        },
                        props:['parentNav','parentCurrentind','parentBlocks','parentBanner','parentTeambg','parentTeam','parentAdvisor','parentClbrtn'],
                    },
                },
            })
        </script>
        <script src="js/common/common.js"></script>
        <script src="js/common/animation.js"></script>
        <script>
            ! function() {
                if($('.mobileDevice').length) return false;
                //封装方法，压缩之后减少文件大小
                function get_attribute(node, attr, default_value) {
                    return node.getAttribute(attr) || default_value;
                }
                //封装方法，压缩之后减少文件大小
                function get_by_tagname(name) {
                    return document.getElementsByTagName(name);
                }
                //获取配置参数
                function get_config_option() {
                    var scripts = get_by_tagname("script"),
                        script_len = scripts.length,
                        script = scripts[script_len - 1]; //当前加载的script
                    return {
                        l: script_len, //长度，用于生成id用
                        z: get_attribute(script, "zIndex", -1), //z-index
                        o: get_attribute(script, "opacity", 1), //opacity
                        c: get_attribute(script, "color", "255,255,255"), //color
                        n: get_attribute(script, "count", 500) //count
                    };
                }
                //设置canvas的高宽
                function set_canvas_size() {
                    canvas_width = the_canvas.width = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth,
                    canvas_height = the_canvas.height = window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight;
                }
             
                //绘制过程
                function draw_canvas() {
                    context.clearRect(0, 0, canvas_width, canvas_height);
                    //随机的线条和当前位置联合数组
                    var e, i, d, x_dist, y_dist, dist; //临时节点
                    //遍历处理每一个点
                    random_lines.forEach(function(r, idx) {
                        r.x += r.xa,
                        r.y += r.ya, //移动
                        r.xa *= r.x > canvas_width || r.x < 0 ? -1 : 1,
                        r.ya *= r.y > canvas_height || r.y < 0 ? -1 : 1, //碰到边界，反向反弹
                        context.fillRect(r.x - 0.5, r.y - 0.5, 1, 1); //绘制一个宽高为1的点
                        //从下一个点开始
                        for (i = idx + 1; i < all_array.length; i++) {
                            e = all_array[i];
                            //不是当前点
                            if (null !== e.x && null !== e.y) {
                                    x_dist = r.x - e.x, //x轴距离 l
                                    y_dist = r.y - e.y, //y轴距离 n
                                    dist = x_dist * x_dist + y_dist * y_dist; //总距离, m
                                dist < e.max && (e === current_point && dist >= e.max / 2 && (r.x -= 0.03 * x_dist, r.y -= 0.03 * y_dist), //靠近的时候加速
                                    d = (e.max - dist) / e.max,
                                    context.beginPath(),
                                    context.lineWidth = d / 2,
                                    context.strokeStyle = "rgba(" + config.c + "," + (d + .8) + ")",
                                    context.moveTo(r.x, r.y),
                                    context.lineTo(e.x, e.y),
                                    context.stroke());
                            }
                        }
                    }), frame_func(draw_canvas);
                }
                //创建画布，并添加到body中
                var the_canvas = document.createElement("canvas"), //画布
                    config = get_config_option(), //配置
                    canvas_id = "c_n" + config.l, //canvas id
                    context = the_canvas.getContext("2d"), canvas_width, canvas_height,
                    frame_func = window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || window.oRequestAnimationFrame || window.msRequestAnimationFrame || function(func) {
                        window.setTimeout(func, 1000 / 45);
                    }, random = Math.random,
                    current_point = {
                        x: null, //当前鼠标x
                        y: null, //当前鼠标y
                        max: 20000
                    },
                    all_array;
                the_canvas.id = canvas_id;
                $('main .professor .content .avatar .intro .draw').append(the_canvas);

                //初始化画布大小
             
                set_canvas_size(), window.onresize = set_canvas_size;
                //当时鼠标位置存储，离开的时候，释放当前位置信息
                window.onmousemove = function(e) {
                    e = e || window.event, current_point.x = e.clientX, current_point.y = e.clientY;
                }, window.onmouseout = function() {
                    current_point.x = null, current_point.y = null;
                };
                //随机生成config.n条线位置信息
                for (var random_lines = [], i = 0; config.n > i; i++) {
                    var x = random() * canvas_width, //随机位置
                        y = random() * canvas_height,
                        xa = 2 * random() - 1, //随机运动方向
                        ya = 2 * random() - 1;
                    random_lines.push({
                        x: x,
                        y: y,
                        xa: xa,
                        ya: ya,
                        max: 12000 //沾附距离
                    });
                }
                all_array = random_lines.concat([current_point]);
                //0.1秒后绘制
                setTimeout(function() {
                    if($('.mobileDevice').length) return false;
                    draw_canvas();
                }, 1300);
            }();
        </script>
        <script>
            ! function() {
                //封装方法，压缩之后减少文件大小
                function get_attribute(node, attr, default_value) {
                    return node.getAttribute(attr) || default_value;
                }
                //封装方法，压缩之后减少文件大小
                function get_by_tagname(name) {
                    return document.getElementsByTagName(name);
                }
                //获取配置参数
                function get_config_option() {
                    var scripts = get_by_tagname("script"),
                        script_len = scripts.length,
                        script = scripts[script_len - 1]; //当前加载的script
                    return {
                        l: script_len, //长度，用于生成id用
                        z: get_attribute(script, "zIndex", -1), //z-index
                        o: get_attribute(script, "opacity", 1), //opacity
                        c: get_attribute(script, "color", "113,174,214"), //color
                        n: get_attribute(script, "count", 500) //count
                    };
                }
                //设置canvas的高宽
                function set_canvas_size() {
                    canvas_width = the_canvas.width = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth,
                    canvas_height = the_canvas.height = window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight;
                }
             
                //绘制过程
                function draw_canvas() {
                    context.clearRect(0, 0, canvas_width, canvas_height);
                    //随机的线条和当前位置联合数组
                    var e, i, d, x_dist, y_dist, dist; //临时节点
                    //遍历处理每一个点
                    random_lines.forEach(function(r, idx) {
                        r.x += r.xa,
                        r.y += r.ya, //移动
                        r.xa *= r.x > canvas_width || r.x < 0 ? -1 : 1,
                        r.ya *= r.y > canvas_height || r.y < 0 ? -1 : 1, //碰到边界，反向反弹
                        context.fillRect(r.x - 0.5, r.y - 0.5, 1, 1); //绘制一个宽高为1的点
                        //从下一个点开始
                        for (i = idx + 1; i < all_array.length; i++) {
                            e = all_array[i];
                            //不是当前点
                            if (null !== e.x && null !== e.y) {
                                    x_dist = r.x - e.x, //x轴距离 l
                                    y_dist = r.y - e.y, //y轴距离 n
                                    dist = x_dist * x_dist + y_dist * y_dist; //总距离, m
                                dist < e.max && (e === current_point && dist >= e.max / 2 && (r.x -= 0.03 * x_dist, r.y -= 0.03 * y_dist), //靠近的时候加速
                                    d = (e.max - dist) / e.max,
                                    context.beginPath(),
                                    context.lineWidth = d / 2,
                                    context.strokeStyle = "rgba(" + config.c + "," + (d + 0.2) + ")",
                                    context.moveTo(r.x, r.y),
                                    context.lineTo(e.x, e.y),
                                    context.stroke());
                            }
                        }
                    }), frame_func(draw_canvas);
                }
                //创建画布，并添加到body中
                var the_canvas = document.createElement("canvas"), //画布
                    config = get_config_option(), //配置
                    canvas_id = "c_n" + config.l, //canvas id
                    context = the_canvas.getContext("2d"), canvas_width, canvas_height,
                    frame_func = window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || window.oRequestAnimationFrame || window.msRequestAnimationFrame || function(func) {
                        window.setTimeout(func, 1000 / 45);
                    }, random = Math.random,
                    current_point = {
                        x: null, //当前鼠标x
                        y: null, //当前鼠标y
                        max: 20000
                    },
                    all_array;
                the_canvas.id = canvas_id;
                $('main #team').append(the_canvas);

                //初始化画布大小
             
                set_canvas_size(), window.onresize = set_canvas_size;
                //当时鼠标位置存储，离开的时候，释放当前位置信息
                window.onmousemove = function(e) {
                    e = e || window.event, current_point.x = e.clientX, current_point.y = e.clientY;
                }, window.onmouseout = function() {
                    current_point.x = null, current_point.y = null;
                };
                //随机生成config.n条线位置信息
                for (var random_lines = [], i = 0; config.n > i; i++) {
                    var x = random() * canvas_width, //随机位置
                        y = random() * canvas_height,
                        xa = 2 * random() - 1, //随机运动方向
                        ya = 2 * random() - 1;
                    random_lines.push({
                        x: x,
                        y: y,
                        xa: xa,
                        ya: ya,
                        max: 12000 //沾附距离
                    });
                }
                all_array = random_lines.concat([current_point]);
                //0.1秒后绘制
                setTimeout(function() {
                    if($('.mobileDevice').length) return false;
                    $('main #team .list .itm:first-child .avatar .draw').append($('main #team canvas'));
                    draw_canvas();
                }, 1300);
            }();
        </script>
        <script src="js/about.js"></script>
    </body>
</html>